<?php

namespace app\base\model\goods;

use think\Model;

class GoodsIntroduceInfo extends Model
{

    // 关闭自动写入时间戳
    protected $autoWriteTimestamp = false;

    protected $table = 'xy_goods.xy_goods_introduce_info';

    const INTRODUCE_TYPE_CAROUSEL = 1;//头部轮播图
    const INTRODUCE_TYPE_CONTENT = 2;//介绍详情图

    public static function getGoodsImgList($goods_id, $introduce_type)
    {
        return self::where('goods_id', $goods_id)->where('introduce_type', $introduce_type)->where('status',
            1)->order('sort_num', 'asc')->column('introduce_url');
    }

}